import { observable, action } from "mobx";
import { getStorage, setStorage } from '../utils/utils';
let user = getStorage('user')

export default class LoginState{
    @observable loginUser = user || {}

    @action loginSuccess(val){
        this.loginUser = { ...val }
        setStorage('user',val)
    }
}